#ifndef FS_TEXTURE_POOL_H
#define FS_TEXTURE_POOL_H

#ifdef _WIN32
#include <windows.h>
#endif

#include <GL/glew.h>
#include <vector>
using namespace std;

typedef struct {
	string textureName;
	GLuint textureID;
	unsigned int loadCount;
} fs_TextureAssociation;

// Used a template for this class from: www.yolinux.com/TUTORIALS/C++Singleton.html
class fs_TexturePool {

public:
	static fs_TexturePool *Instance();
	GLuint loadTexture(string filename);
	void unloadTexture(GLuint glTextureID);
	static void Destroy();

private:
	static fs_TexturePool *m_instance;

	fs_TexturePool() {};
	fs_TexturePool(fs_TexturePool const&) {};
	fs_TexturePool& operator=(fs_TexturePool const&) {};
	~fs_TexturePool();

	vector<fs_TextureAssociation> loadedTextures;
};

#endif // #ifndef FS_TEXTURE_POOL_H